package zdy.web.bean;

import javax.servlet.http.Cookie;

public class COOKY {
	public static Cookie getCookieByName(Cookie[] cookies,String xxx){
		   if( cookies != null ){	     
		      for (int i = 0; i < cookies.length; i++){
		    	 Cookie cookie = cookies[i];
	             if (xxx.equals(cookie.getName())){
	               return cookie ; //URLDecoder.decode(cookie.getValue(), "utf-8")
	             }
		      }
		  }
		   return null ;
	}
}
